#
# Constantes pour la compilation des programmes
#

export CC = gcc
export LD = gcc
export AR = ar crus
export CDEBUG = -g -DVERBOSE
export CFLAGS = -Wall
export MAKE = make 

#
# Repertoires du projet
#
#IPC Workflow_engine Workflows_admin Models
DIRS=Socket Threads IPC Workflow_engine Workflow_admin


#
# Cible generale
#

all: 
	for dir in $(DIRS); do\
		$(MAKE) all -C $$dir;\
	done



#
# Cible debug
#
debug: CFLAGS+= $(CDEBUG)
debug:
	for dir in $(DIRS); do\
		$(MAKE) all -C $$dir;\
	done

#
# Cible de nettoyage
#

clean:
	@echo
	@echo Debut du nettoyage
	for dir in $(DIRS); do\
		$(MAKE) clean -C $$dir;\
	done
	@echo Fin du nettoyage
	@echo
